<h1>Show Tasks</h1>

<h3>Project <%= @project.project_reference %></h3>

<table>
  <tr>
    <th>Tache</th>
    <th></th>
  </tr>
<% i=0 %>
<% @project.tasks.each do |task| %>
  <tr>
    <td><%= task.name %></td>
    <td><%= link_to 'delete', destroy_tasks_project_path(@project.id,:task => @taskProject[i]) %></td>
    <% i=i+1 %>
  </tr>
<% end %>
</table>


<%= link_to 'Add a task', add_tasks_project_path(@project.id) %> | 
<%= link_to 'Back', projects_path %>